<script setup lang="ts">
import {ref} from "vue";
import { getSearch} from "@/api/more";

let DtList = ref()
getSearch().then(res=>{
    // console.log(res)
    DtList.value = res.rows[10].itemList
    // console.log(DtList.value)
})
</script>

<template>
    <div>
        <div id="banner"></div>
        <div id="main">
            <div class="one" v-for="item in DtList" :key="item.id">
                <p>{{item.title}}</p>
                <p>{{item.intro}}</p>
            </div>
        </div>
    </div>
</template>

<style scoped>
#banner{
    width: 375px;
    height: 160px;
    background-image: url("@/assets/images/0bc5f9e6c4b9fc5a1ec0e4a18671f2c.png");
    background-repeat: no-repeat;
    background-size: 375px 160px;
}
#main{
    width: 350px;
    margin: -70px auto 0;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;


    .one{
        width: 120.5pt;
        height: 50pt;
        margin-bottom: 10px;
    //background-color: #c81127;
        p{
            height: 20px;
            font-size: 10px;
        //background-color: #c81127;
            overflow: hidden;
            white-space: nowrap;
            text-overflow: ellipsis;
        }
    }
}
</style>